
import { loadInfoStutrainInfoList,loadAlDegreegraduInfo } from "../../services/mentor"
export default {

  namespace: 'studentsBasicInformationModule',

  state: {
    loadInfoStutrainList:[],
    loadAlDegreegraduList:[]
  },

  effects: {
    *loadInfoStutrainInfo({ payload }, { call, put }) {
      let nav = yield loadInfoStutrainInfoList(payload)
      yield put({
        type: 'loadInfoStutrain', payload: nav.rows
      });
    },
    
    *loadAlDegreegradu({ payload }, { call, put }) {
      let nav = yield loadAlDegreegraduInfo(payload)
      yield put({
        type: 'loadAlDegree', payload: nav
      });
    }
  },

  reducers: {
    loadInfoStutrain(state, { payload }) {
      state.loadInfoStutrainList = payload;
      return {
        ...state,
        ...payload,
      }
  },
  loadAlDegree(state, { payload }) {
    state.loadAlDegreegraduList = payload;
    return {
      ...state,
      ...payload,
    }
},
}

};
